% latex table generated in R 4.4.0 by xtable 1.8-4 package
% Thu Apr 10 09:22:37 2025
\begin{table}[ht]
\centering
\scalebox{0.55}{
\begin{tabular}{rrrrrrrrrrrrr}
  \hline
 & Paul '12 & Romney '12 & Gingrich '12 & Santorum '12 & Trump '16 & Cruz '16 & Kasich '16 & Barletta '18 & Christiana '18 & Barnette '22 & Oz '22 & McCormick '22 \\ 
  \hline
McCain '08 & -0.125 & \cellcolor{gray!80}0.238 & -0.137 & -0.099 & 0.059 & -0.141 & 0.084 & 0.018 & -0.018 & -0.140 & 0.079 & 0.093 \\ 
  Huckabee '08 & -0.023 & -0.173 & 0.128 & 0.167 & 0.022 & 0.100 & -0.125 & -0.051 & 0.051 & 0.081 & -0.063 & 0.008 \\ 
  Paul '08 & 0.150 & -0.140 & 0.070 & -0.019 & -0.098 & 0.092 & 0.012 & 0.014 & -0.014 & 0.100 & -0.036 & -0.123 \\ 
  Paul '12 & 1.000 & \cellcolor{gray!60}-0.482 & -0.176 & -0.158 & -0.110 & 0.010 & 0.096 & -0.046 & 0.046 & 0.077 & -0.089 & -0.057 \\ 
  Romney '12 & \cellcolor{gray!60}-0.482 & 1.000 & \cellcolor{gray!60}-0.438 & \cellcolor{gray!60}-0.491 & 0.044 & -0.150 & 0.118 & 0.096 & -0.096 & -0.116 & 0.099 & 0.078 \\ 
  Gingrich '12 & -0.176 & \cellcolor{gray!60}-0.438 & 1.000 & -0.156 & -0.025 & 0.136 & -0.122 & -0.036 & 0.036 & 0.048 & -0.015 & -0.091 \\ 
  Santorum '12 & -0.158 & \cellcolor{gray!60}-0.491 & -0.156 & 1.000 & 0.092 & 0.070 & -0.172 & -0.062 & 0.062 & 0.030 & -0.024 & 0.035 \\ 
  Trump '16 & -0.110 & 0.044 & -0.025 & 0.092 & 1.000 & \cellcolor{gray!60}-0.532 & \cellcolor{gray!60}-0.598 & 0.170 & -0.170 & -0.173 & \cellcolor{gray!80}0.214 & 0.074 \\ 
  Cruz '16 & 0.010 & -0.150 & 0.136 & 0.070 & \cellcolor{gray!60}-0.532 & 1.000 & \cellcolor{gray!30}-0.217 & -0.111 & 0.111 & 0.133 & -0.073 & -0.145 \\ 
  Kasich '16 & 0.096 & 0.118 & -0.122 & -0.172 & \cellcolor{gray!60}-0.598 & \cellcolor{gray!30}-0.217 & 1.000 & -0.067 & 0.067 & 0.049 & -0.171 & 0.110 \\ 
  Barletta '18 & -0.046 & 0.096 & -0.036 & -0.062 & 0.170 & -0.111 & -0.067 & 1.000 & -1.000 & -0.008 & 0.008 & 0.004 \\ 
  Christiana '18 & 0.046 & -0.096 & 0.036 & 0.062 & -0.170 & 0.111 & 0.067 & -1.000 & 1.000 & 0.008 & -0.008 & -0.004 \\ 
  Barnette '22 & 0.077 & -0.116 & 0.048 & 0.030 & -0.173 & 0.133 & 0.049 & -0.008 & 0.008 & 1.000 & \cellcolor{gray!60}-0.464 & \cellcolor{gray!30}-0.372 \\ 
  Oz '22 & -0.089 & 0.099 & -0.015 & -0.024 & \cellcolor{gray!80}0.214 & -0.073 & -0.171 & 0.008 & -0.008 & \cellcolor{gray!60}-0.464 & 1.000 & \cellcolor{gray!30}-0.269 \\ 
  McCormick '22 & -0.057 & 0.078 & -0.091 & 0.035 & 0.074 & -0.145 & 0.110 & 0.004 & -0.004 & \cellcolor{gray!30}-0.372 & \cellcolor{gray!30}-0.269 & 1.000 \\ 
   \hline
\end{tabular}
}
\caption{Correlations of vote shares in Republican primaries from all Pennsylvania precincts (n=8151-9008).} 
\label{f:pagop}
\end{table}
